package fr.upmc.cie.data.dbaccess;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;

public abstract class DBProvider {
	
	
	protected static final String DB_NAME = "fluxrss.db";
	protected static final int DB_VERSION = 1;
	
	protected Context context;
	protected SQLiteDatabase db;
	protected static DBOpenHelper openHelper;
	
	public static SQLiteDatabase getDB(Context context){
		if (openHelper==null){
			openHelper = new DBOpenHelper(context, DB_NAME, DB_VERSION);
		}
		return openHelper.getWritableDatabase();
	}

}
